package com.xiaoyu.izf.controller;

import com.xiaoyu.izf.service.YqfDataGetService;
import com.xiaoyu.izf.service.YqfStoreStatsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/test")
public class TestController {
    @Autowired
    private YqfDataGetService yqfDataGetService;
    @Autowired
    private YqfStoreStatsService yqfStoreStatsService;

    @RequestMapping("/t1")
    public String t1(){
        yqfDataGetService.merchantInfoGet();
        yqfDataGetService.storeGet();
        try {
            yqfDataGetService.storeStateDayGet("2019-09-27");
        } catch (Exception e) {
            e.printStackTrace();
        }
        return "t1";
    }

    @RequestMapping("/t2")
    public String t2(){
        yqfStoreStatsService.merchantForList(null,null);
        return "t2";
    }
}
